<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="tiles" uri="http://tiles.apache.org/tags-tiles"%>
<%@ taglib prefix="s" uri="/struts-tags"%>

<%-- 翻页 --%>
<s:if test="pageCount != 0">
	<div class="page w1100">
		<ul class="page">
			<li class="page">
				<s:if test="pageIndex == 0">
					<span class="disabled"><s:text name="common.button.prevPage" /></span>
				</s:if>
				<s:else>
					<s:a action="%{actionPath}?pageIndex=%{pageIndex - 1}%{paramsUrl}">
						<s:text name="common.button.prevPage" />
					</s:a>
				</s:else>
			</li>
			<s:iterator begin="0" end="pageCount - 1" step="1" status="st">
				<li class="page">
					<s:if test="pageIndex == #st.index">
						<span class="current"><s:property value="#st.index + 1" /></span>
					</s:if>
					<s:else>
						<s:a action="%{actionPath}?pageIndex=%{#st.index}%{paramsUrl}">
							<s:property value="#st.index + 1" />
						</s:a>
					</s:else>
				</li>
			</s:iterator>
			<li class="page">
				<s:if test="pageIndex == pageCount - 1 || pageCount == 0">
					<span class="disabled"><s:text name="common.button.nextPage" /></span>
				</s:if>
				<s:else>
					<s:a action="%{actionPath}?pageIndex=%{pageIndex + 1}%{paramsUrl}">
						<s:text name="common.button.nextPage" />
					</s:a>
				</s:else>
			</li>
		</ul>
		<!-- 取消浮动元素 -->
		<ul class="clear"></ul>
	</div>
</s:if>